#{extends 'main.html' /}
<div class="page-group">
    <div class="page page-current" id="work-order-list">
        <header class="bar bar-nav">
            <a href="javascript:history.go(-1);" class="icon icon-left pull-left"></a>
            <h1 class="title">报修列表</h1>
        </header>
        <section class="repairList content scroll_y" style="padding-bottom:5rem ;">
            <div class="list-block">
            #{ifnot issueList}
                <ul>
                    <li class="item-content">
                        您当前没有报修记录
                    </li>
                </ul>
            #{/ifnot}
                <ul>
                #{list issueList , as :'issue'}
                    <li class="item-content">
                        <div class="item-inner">
                            <a href="/issue/issueDetail/${issue?.id}"><div class="item-title">${issue?.issueName}</div>
                            <div class="item-after">${issue?.createdAt?.format('yyyy-MM-dd')}</div></a>
                        </div>
                    </li>
                #{/list}
                </ul>
            </div>
        </section>
        <div class="footbtn bar bar-tab">
            <a href="/issue/index/REPAIR" class="button button-link button-fill button-big button-primary external">新增报修</a>
        </div>
    #{include 'weixin/footer.html'/}
    </div>
</div>
<script type="text/javascript">
    $(function () {
        var error="${flash['error']}";
        console.log(error);
        if(error) $.toast(error);
    })

</script>